package cn.valorin.event;

import org.bukkit.Material;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.inventory.FurnaceSmeltEvent;
import org.bukkit.inventory.ItemStack;

import cn.valorin.item.RawZongzi3;
import cn.valorin.util.CheckLore;

public class CookEvent implements Listener {
	@EventHandler
	public void burn(FurnaceSmeltEvent e) {
		ItemStack source = e.getSource();
		if (!source.getType().equals(Material.INK_SACK)) { return; }
		if (!CheckLore.check(source, RawZongzi3.get(null))) {
			e.setCancelled(true);
			return;
		}
	}
}
